var express = require('express');
var openUrl = require('./openUrl');
var app = express();

const hostname = "127.0.0.1";
const port = 3000;

app.get("/", function(req, resp){
    resp.send("Hello World");
});

app.listen(port, hostname, runningHandler);

function runningHandler(){
    let url = "http://" + hostname + ":" + port + "/";
    console.log(`Server is running at ${hostname}:${port}`);
    openUrl(url);
}
// console.log(app);